package puntaelena.graphsupport;

import laboratoryQ.common.IDisposable;


public class NativeGraphGenerator implements IGraphGenerator, IDisposable {
	/**
	 * reinterpret_cast< int > ( boost::shared_ptr< IGraphOperation > * )
	 */
	private int nativeGenerator_ptr;

	public NativeGraphGenerator(int nativeGeneratorPtr) {
		nativeGenerator_ptr = nativeGeneratorPtr;
	}

	@Override
	public Graph generate(GenerateGrSettings settings) {
		return NativeGraphSupportBridge.nativeGenerate( nativeGenerator_ptr, settings );
	}

	@Override
	public void dispose() {
		NativeGraphSupportBridge.nativeDisposeGenerator(nativeGenerator_ptr);
		nativeGenerator_ptr = 0;
	}
}
